package com.fupeng.tecent;

import java.util.concurrent.ConcurrentHashMap;

/**
 * Created by lecky on 2016/9/11 0011.
 */
public class Demo {
    public static void main(String[] args) {
    }

    private static StringBuffer result=null;
    public static String solution(int left,int right,int in){
        if(right-left+1<=6)
            return result.toString();
        int mid = (left+right)>>1;
        if(in<mid){
            result.append("0");
            solution(left,mid,in);
        }else{
            result.append("1");
            solution(mid,right,in);
        }
        return null;
    }
}
